package com.mspbots.core.wise.controller;

import com.mspbots.core.AbstractBaseController;
import com.mspbots.core.wise.model.TenantCompanies;
import com.mspbots.core.wise.service.TenantCompaniesService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.concurrent.Callable;

/**
 * TenScheduleController
 *
 * @author Alex bob(https://github.com/vnobo)
 * @date Created by 2019/6/4
 */
@RestController
@RequestMapping(path = "tenant/companies")
public class TenantCompaniesController extends AbstractBaseController<TenantCompanies, TenantCompaniesService> {

    @GetMapping(path = "/listByName")
    public Callable listByName(TenantCompanies queryParams) {
        return () -> this.service.getCompaniesList(queryParams);
    }
}
